package com.atguigu.yygh.cmn.service;

import com.atguigu.yygh.common.R;
import com.atguigu.yygh.model.cmn.Dict;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * @Author zhmwi
 * @Date 2021/7/5
 * @Dersciption
 */
public interface DictService extends IService<Dict> {

    //查询树节点
    public List<Dict> queryTreeChildById(@PathVariable Long id);
    //导出数据
    void exportData(HttpServletResponse response);
    //导入数据
    void importData(MultipartFile file);

    //远程调用使用
    //根据字典类型编号和唯一value值获取字典名称
    String getDictionaryNameByDictCodeAndValue(String dictCode, String value);

    //根据dictCode查询子类字典集合
    List<Dict> findByDictCode(String dictCode);
    //根据dictId查询子类字典集合
    List<Dict> getByDictId(Long dictId);
}
